﻿@using htmlHelpers.Enums
@using htmlHelpers.Extensions
@using htmlHelpers.Html
@model sushi.Models.Author

@{
    ViewBag.Title = "Create";
    Layout = "~/Views/SharedAdmin/_Layout.cshtml";
}
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

 <div class="row-fluid">
  @(
	Html.Sushi().Layout()
		.SetLayoutSize(GridSize.span3)
		.AddElement(Html.Sushi().SideBar()
						.AddInnerHTML("<ul class=\"nav nav-list\"><li class=\"nav-header\">Sidebar</li>" +
									"<li class=\"active\"><a href=\"#\">Link</a></li>" +
									"<li><a href=\"#\">Link</a></li>" +
									"</ul>"))
	)
     <div class="span9">
         <div class="row-fluid">
@using (Html.BeginForm("Create", "Author", FormMethod.Post, new {@class ="form-stacked"})) {
    @Html.ValidationSummary(true)
		<fieldset>
        <legend>Author</legend>

						@Html.Sushi().Field(model => model.Name).SetGridSize(GridSize.span6)
						@Html.Sushi().Field(model => model.Biography).SetGridSize(GridSize.span6)
						@Html.Sushi().Field(model => model.WebSite).SetGridSize(GridSize.span6)
						@Html.Sushi().Field(model => model.Email).SetGridSize(GridSize.span6)
						@Html.Sushi().Field(model => model.Image).SetGridSize(GridSize.span6)
					  @(
				Html.Sushi().Panel()
					.AddElement(Html.Sushi().Button().SetType(ButtonType.Primary).SetCaption("Aceptar"))
					.AddElement(Html.Sushi().Button().SetType(ButtonType.Primary).SetBehaviour(HtmlBehaviourType.Link).SetAction("Index").SetCaption("Volver"))
				)
			</fieldset>
	}
	</div>
	</div>
</div>

